set(srcs
    "lib/lua/lundump.c"
    "lib/lua/lmem.c"
    "lib/lua/ltm.c"
    "lib/lua/linit.c"
    "lib/lua/lbaselib.c"
    "lib/lua/lopcodes.c"
    "lib/lua/lauxlib.c"
    "lib/lua/lstrlib.c"
    "lib/lua/lcode.c"
    "lib/lua/lzio.c"
    "lib/lua/lvm.c"
    "lib/lua/ltablib.c"
    "lib/lua/lapi.c"
    "lib/lua/lstring.c"
    "lib/lua/llex.c"
    "lib/lua/lparser.c"
    "lib/lua/lmathlib.c"
    "lib/lua/liolib.c"
    "lib/lua/ldump.c"
    "lib/lua/ltable.c"
    "lib/lua/loslib.c"
    "lib/lua/lfunc.c"
    "lib/lua/lgc.c"
    "lib/lua/lcorolib.c"
    "lib/lua/loadlib.c"
    "lib/lua/lobject.c"
    "lib/lua/ldo.c"
    "lib/lua/ldblib.c"
    "lib/lua/lutf8lib.c"
    "lib/lua/lstate.c"
    "lib/lua/lctype.c"
    "lib/lua/ldebug.c"
    "src/script.c"
    "src/l_evse_lib.c"
    "src/l_mqtt_lib.c"
    "src/l_json_lib.c"
    "src/l_aux_lib.c"
    "src/l_board_config_lib.c"
    )

idf_component_register(SRCS "${srcs}"
                    INCLUDE_DIRS "include" 
                    PRIV_INCLUDE_DIRS "src" "lib/lua"
                    PRIV_REQUIRES nvs_flash app_update json mqtt esp_timer
                    REQUIRES config evse peripherals protocols serial logger)
